import axios from 'axios';

let baseUrl = "http://47.96.143.29:5432";

// axios.defaults.headers.common['Authorization'] ="Bearer "+localStorage.getItem("token");
axios.defaults.headers.common['token'] = localStorage.getItem("token");

export const GET = (url,params)=>{
    return axios.get(`${baseUrl}${url}`,{params:params}).then(data=>data);
}
export const POST = (url,params)=>{
    return axios.post(`${baseUrl}${url}`,params).then(data=>data);
}